package com.lh.project.controller;

import com.lh.project.common.BaseResponse;
import com.lh.project.common.ResultUtils;
import com.lh.project.service.VoucherOrderService;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
@RequestMapping("/voucherOrder")
@RestController
public class VoucherOrderController {

    @Resource
    private VoucherOrderService voucherOrderService;


    @PostMapping("/post")
    public BaseResponse<String> setVoucherOrder(@RequestBody Long id){

        String result = voucherOrderService.setVoucherOrder(id);

        return ResultUtils.success(result);
    }
}
